package com.iron.sfm.api.feign.fallback;

import com.iron.common.core.util.R;
import com.iron.sfm.api.entity.SysLog;
import com.iron.sfm.api.feign.SysLogFeign;
import lombok.Setter;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

/**
 * @author YT
 * @date 2019-06-27
 */
@Slf4j
@Component
public class SysLogFeignFallbackImpl implements SysLogFeign {
    @Setter
    private Throwable cause;

    /**
     * 保存日志
     *
     * @param sysLog 日志实体
     * @return
     */
    @Override
    public R<Boolean> saveLog(SysLog sysLog) {
        log.info("feign 插入日志失败", cause);
        return null;
    }
}
